<template>
	<view class="content">
		<view class="header">
			<view class="top">
				<u-icon class="u-icon" name="arrow-left" color="#fff" size="16" @click='back'></u-icon>
				<p>订单详情</p>
				<span></span>
			</view>
			<view class="tops">
				<span class="Dai">待支付</span>
				<view class="zhifu">
					<span class="Sheng">支付剩余
						<span>
							<u-count-down class="dao" :time="30 * 60 * 60 * 1000" format="HH:mm:ss"></u-count-down>
						</span></span>
				</view>

			</view>
		</view>
		<view class="main">
			<p>取票号 : {{ticketnum}}</p>
			<view class="maina">
				<span>{{datepast}}</span>
				<span>{{dateanti}}</span>
			</view>
			<view class="mainb">
				<span>{{timepast<10?'0'+timepast:timepast}}:{{timepast1<10?'0'+timepast1:timepast1}}</span>
				<span>经停信息</span>
				<span>{{timeanti<10?'0'+timeanti:timeanti}}:{{timeanti1<10?'0'+timeanti1:timeanti1}}</span>
			</view>
			<view class="mainc">
				<view class="maincone">
					<span>{{addpast}}</span>
					<u-icon class="u-icon" name="map-fill" color="#000" size="14"></u-icon>
				</view>
				<span>G{{num}}</span>
				<view class="mainctwo">
					<u-icon class="u-icon" name="map-fill" color="#000" size="14"></u-icon>
					<span>{{addanti}}</span>
				</view>
			</view>
			<view class="maind">
				<view class="maindone">
					<view class="maindones">
						<span>{{name}}</span>
						<span>{{show}}</span>
					</view>
					<span class="sp">{{seat}}￥{{money}}</span>
				</view>
				<view class="maindtwo">
					<span>身份证 {{card}}</span>
					<view class="maindtwos">
						<span>靠窗</span>
						<span>{{carr}}</span>
					</view>
				</view>
				<view class="mainthird">
					<span>出票成功</span>
				</view>
			</view>
		</view>
		<view class="foot">
			<view class="footone">
				<view class="footonea">
					<p>订单号</p>
					<p>{{ordernum}}</p>
				</view>
				<view class="footoneb">
					<p>通知手机</p>
					<p>{{iphone}}</p>
				</view>
			</view>
			<view class="foottow">
				<view class="foottowa">
					<p>成人票</p>
					<p>￥{{money}}x{{Adult}}张</p>
				</view>
				<view class="foottowb">
					<p>订单总计</p>
					<p class="foottowbp">￥{{money}}</p>
				</view>
			</view>
		</view>
		<view class="Butt" style="width: 100%;
			height: 10vh;
			background-color: white;
			position: absolute;
			bottom:0;
			">
			<button style="background-color: #E02020;width: 90%; border-radius: 50rpx; color: white;"
				@click="zhifu">去支付</button>
		</view>
	</view>

</template>

<script>
	export default {
		data() {
			return {
				remainder: '45:00',
				ticketnum: 'BW123455',
				datepast: '06月15日周二',
				dateanti: '06月15日周二',
				timepast: '06',
				timepast1: '24',
				timeanti: '07',
				timeanti1: '21',
				addpast: '合肥南',
				addanti: '南京南',
				num: 'G7740',
				name: '王一默',
				show: '成人票',
				seat: '一等座',
				money: '107',
				card: '110102**********28',
				carr: '03车厢16A号',
				ordernum: 'E369941878',
				iphone: '188123456789',
				Adult: '1',
				ordersum: '107',
			}
		},
		methods: {
			zhifu() {
				uni.navigateTo({
					url: '/pages/order Detailed Data/order Detailed Data',
				});
			},
			back() {
				uni.navigateBack({
					delta: 3
				});
			},
		},
		onLoad(option) {
			if (option.objone) {
				let orderfilling = decodeURIComponent(option.objone)
				let orderfillingPar = JSON.parse(orderfilling)
				console.log(orderfillingPar, '接受orderfilling传来的参数');
				this.datepast = orderfillingPar.date
				this.dateanti = orderfillingPar.date
				this.timepast = orderfillingPar.dates
				this.timepast1 = orderfillingPar.datev
				this.timeanti = orderfillingPar.dates1
				this.timeanti1 = orderfillingPar.datev1
				this.addpast = orderfillingPar.city
				this.addanti = orderfillingPar.citytwo
				this.name = orderfillingPar.name
				this.num = orderfillingPar.ceci
				this.money = orderfillingPar.money
				this.show = orderfillingPar.arr
			}
		}
	}
</script>

<style lang="scss">
	.content {
		width: 100vw;
		height: 100vh;
		background-color: rgb(239, 239, 239);
	}

	.header {
		width: 100vw;
		height: 38vh;
		background-color: #00acbd;
		border-bottom-right-radius: 40rpx;
		border-bottom-left-radius: 40rpx;

		.top {
			width: 100%;
			height: 80rpx;
			padding-top: 80rpx;
			display: flex;
			align-items: center;

			.u-icon {
				margin-left: 20rpx;
			}

			p {
				margin-left: 245rpx;

				color: #fff;
				font-size: 35rpx;
			}
		}

		.tops {
			width: 95.5%;
			height: 8vh;
			margin: 0 auto;
			margin-top: 15rpx;
			background-color: white;
			border-radius: 25rpx;
			display: flex;
			justify-content: space-between;
			line-height: 8vh;
		}

		.zhifu {
			width: 140px;

			span {
				display: inline-block;
			}
		}

		.Dai {
			margin-left: 26rpx;
			color: red;
			font-size: 45rpx;
			font-weight: bold;
		}

		.Sheng {
			margin-right: 25rpx;
		}
	}

	.main {
		width: 96vw;
		height: 38vh;
		background-color: #fff;
		margin-left: 2vw;
		border-radius: 20rpx;
		margin-top: -205rpx;

		p {
			font-size: 25rpx;
			padding: 40rpx;
		}

		.maina {
			width: 90%;
			height: 35rpx;
			margin: 0 auto;
			display: flex;
			justify-content: space-between;
			margin-top: -20rpx;

			span:nth-child(1) {
				font-size: 30rpx;
				color: #4d4d4d;
			}

			span:nth-child(2) {
				font-size: 30rpx;
				color: #4d4d4d;
			}
		}

		.mainb {
			width: 90%;
			height: 70rpx;
			margin: 0 auto;
			display: flex;
			justify-content: space-between;
			align-items: center;

			span:nth-child(1) {
				font-weight: 800;
				font-size: 45rpx;
			}

			span:nth-child(3) {
				font-weight: 800;
				font-size: 45rpx;
			}

			span:nth-child(2) {
				display: inline-block;
				padding: 10rpx;
				width: 120rpx;
				height: 40rpx;
				border: 2rpx solid #ccc;
				border-radius: 40rpx;
				font-size: 22rpx;
				text-align: center;
				line-height: 40rpx;
			}
		}

		.mainc {
			width: 90%;
			height: 70rpx;
			margin: 0 auto;
			display: flex;
			align-items: center;
			justify-content: space-between;

			span {
				font-size: 32rpx;
			}

			.maincone,
			.mainctwo {
				display: flex;
				justify-content: space-between;
				align-items: center;
				width: 130rpx;
				height: 100%;
			}
		}

		.maind {
			width: 90%;
			height: 220rpx;
			background: #f5f5f5;
			border-radius: 20rpx;
			margin: 0 auto;
			margin-top: 10rpx;

			.maindone {
				.sp {
					font-size: 32rpx;
					margin-right: -100rpx;
				}

				width: 100%;
				height: 90rpx;
				align-items: center;
				display: flex;
				justify-content: space-around;

				.maindones {
					display: flex;
					align-items: center;
					margin-left: -100rpx;

					span:nth-child(1) {
						font-weight: 800;
						font-size: 32rpx;
					}

					span:nth-child(2) {
						border-radius: 10rpx;
						border: 2rpx solid #d2d2d2;
						text-align: center;
						display: inline-block;
						font-size: 26rpx;
						width: 90rpx;
						height: 40rpx;
						margin-left: 15rpx;
						color: #d2d2d2;
					}
				}

			}

			.maindtwo {
				display: flex;
				justify-content: space-around;
				align-items: center;
				width: 100%;
				height: 50rpx;

				span:nth-child(1) {
					font-size: 28rpx;
					color: #ccc;
				}

				.maindtwos {
					width: 260rpx;
					height: 50rpx;
					display: flex;
					justify-content: space-around;
					align-items: center;

					span:nth-child(1) {
						font-size: 24rpx;
						display: inline-block;
						width: 60rpx;
						height: 30rpx;
						text-align: center;
						border: 2rpx solid #33c075;
						color: #33c075;
					}

					span:nth-child(2) {
						font-size: 30rpx;
					}
				}
			}

			.mainthird {
				span {
					color: #33c075;
					font-size: 24rpx;
					margin-left: 18rpx;
				}
			}
		}
	}

	.foot {
		width: 96vw;
		height: 440rpx;
		margin: 0 auto;
		margin-top: 20rpx;

		.footone {
			width: 100%;
			height: 120rpx;
			background: #fff;
			border-radius: 20rpx;

			.footonea {
				width: 90%;
				height: 60rpx;
				margin: 0 auto;
				display: flex;
				align-items: center;
				border-bottom: 2rpx solid #ccc;
				font-size: 20rpx;
				justify-content: space-between;
			}

			.footoneb {
				width: 90%;
				height: 60rpx;
				margin: 0 auto;
				display: flex;
				align-items: center;
				font-size: 20rpx;
				justify-content: space-between;
			}
		}

		.foottow {
			width: 100%;
			height: 120rpx;
			background: #fff;
			margin-top: 20rpx;
			border-radius: 20rpx;

			.foottowa {
				width: 90%;
				height: 60rpx;
				margin: 0 auto;
				display: flex;
				align-items: center;
				border-bottom: 2rpx solid #ccc;
				font-size: 20rpx;
				justify-content: space-between;
			}

			.foottowb {
				width: 90%;
				height: 60rpx;
				margin: 0 auto;
				display: flex;
				align-items: center;
				font-size: 20rpx;
				justify-content: space-between;

				.foottowbp {
					color: #ff7a00;
					font-weight: 800;
					font-size: 25rpx;
				}

			}
		}

		.Butt {}
	}
</style>